
import models.Company;
import play.jobs.Job;
import play.jobs.OnApplicationStart;
import play.test.Fixtures;

/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

/**
 *
 * @author Jarjarbing
 */



@OnApplicationStart
public class Bootstrap extends Job {
    
    @Override
    public void doJob() {
        // Check if the database is empty
        if(Company.count() == 0) {
            Fixtures.loadModels("initial-data.yml");
        }
    }
}
